﻿@namespace Blazorise
@inherits BaseComponent
@if ( HasErrorMessages )
{
    <ul @ref="@ElementRef" id="@ElementId" class="@ClassNames" style="@StyleNames" @attributes="@Attributes">
        @Label

        @foreach ( var errorMessage in ErrorMessages )
        {
            @if ( string.IsNullOrEmpty( errorMessage ) )
            {
                continue;
            }

            <li class="@ErrorClassNames">@errorMessage</li>
        }
        @ChildContent
    </ul>
}